<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var arr = [1,2,3];
        // console.log(arr.__proto__)
        console.log(arr.__proto__ == Array.prototype)//true
        // console.log(arr.__proto__.__proto__)
        console.log(arr.__proto__.__proto__== Object.prototype)//true
        console.log(arr.__proto__.__proto__.__proto__)//null

        console.log(arr.toString())//1,2,3

        var obj = {name:"cheng",age:18}//私有属性
        Object.prototype.sex ="男"//公有属性
        console.log(obj.hasOwnProperty("name"))//true私有属性
        console.log(obj.hasOwnProperty("sex"))//false
        
        console.log(obj)
    </script>
</body>
</html>